
<?php if($recent){?>
<div class="widget">
    <div class="widgetTitle">
        <h3><?= Config::get('Site::recent.title') ;?> </h3>
           
    </div>
    <!-- /.widgetTitle -->
    <div class="widgetContent">
        <ul class="aside-list">
            <?php foreach($recent as $recent):?>
            <li class="">
                <div class="alignLeft col-sm-8 col-xs-8">
                    <h3><a href="<?= Url::base();?>/<?= Commoncall::postLink($recent->id);?>"><?= Str::title($recent->title);?></a></h3>

                    <p>
                        <?= ($recent->address1 ? $recent->address1 : null) ;?>
                        <?= ($recent->address2 ? ', '.$recent->address2 : null) ;?>
                    </p>

                    <p>
                        <?php foreach(Terms::location($recent->id) as $loc):?>
                            <a href="<?= Url::base();?>/<?= Locations::findPK($loc->value)->slug;?>"><?= Locations::findPK($loc->value)->name;?>, </a>
                        <?php endforeach;?>
                    </p>

                    <p>
                        <?php foreach(Terms::category($recent->id) as $cat):?>
                            <a href="<?= Url::base();?>/<?= Str::slug(Location::get());?>/<?= Categories::findPK($cat->value)->slug;?>" class="text-warning"><?= Categories::findPK($cat->value)->name;?>,</a>
                        <?php endforeach;?>
                    </p>

                </div>
                <div class="alignRight col-sm-4 col-xs-4">

                    <img class="img-responsive" src="<?= URL::base();?>/storage/uploads/logos/<?= $recent->logo;?>" alt="">
                </div>
            </li>
            <?php endforeach;?>


        </ul>
    </div>
    <!-- /.widgetContent ---->
</div>
<!-- /.widget -->
<?php }?>